<?php

if (!defined('BASEPATH'))
    exit('No direct script access allowed');

require_once APPPATH . "/third_party/tcpdf/tcpdf.php";

/**
 *
 * @version 1.0
 * @author xpl0it
 */
class Customer_report extends TCPDF {

    function __construct() {
        parent::__construct();
        $this->load->model('authmodel', 'authen');
        $this->load->model('customer_model', 'customer');
        $this->load->model('customer_area_model');
        $this->output->enable_profiler(TRUE);
    }

    function index() {
        
    }

    /*
      function Header() {

      }
     */

    function preview($id) {

        ini_set('max_execution_time', 1200);
        $this->SetMargins(10, 10, 10);
        $this->SetAutoPageBreak(TRUE, 10);
        $this->setPrintHeader(false);
        $this->setPrintFooter(false);

        $this->AddPage();

        $this->Cell(0, 9, $id . " {$_POST['cm_fname']}", 1, 1, 'L', 0);
        $this->Output(date("Y-m-d") . '_costomer.pdf', 'I');
    }

    /*
      function Footer() {
      $height = 6;
      $this->SetY(-11);
      $this->SetFont('', '', 12);

      $this->Cell(150, $height, 'พิมพ์เมื่อ : วันที่ ' . $this->h_date_time, 0, 0, 'L');
      $this->Cell(0, $height, '  หน้า ' . $this->PageNo() . ' / ' . $this->getAliasNbPages(), 0, false, 'R');
      $this->Ln();
      }
     */
}

/* End of file customer.php */
/* Location: ./application/controllers/admin/customer.php */